import $http from "../http"

// 获取奖惩记录列表
export const getrewardAndPunishmentList = params => {
    params.queryData && (params = { ...params, ...params.queryData });
    delete params.queryData;
    return $http.get("/rewardAndPunishment", params)
};

// 获取奖惩详情
export const getRewardAndPunishmentDetail = params => $http.get(`/rewardAndPunishment/${params}`);

// 新增奖惩记录
export const createRewardAndPunishment = params => $http.post(`/rewardAndPunishment`, params);

// 修改奖惩内容
export const updateRewardAndPunishment = params => $http.put(`/rewardAndPunishment/${params._id}`, params)

// 删除奖惩记录
export const deleteRewardAndPunishment = params => $http.post("/deleteRewardAndPunishment", params)